package com.mark.media.controller.v1;

import com.mark.media.apis.AdChannelControllerApi;
import com.mark.media.service.AdChannelService;
import com.mark.model.common.dtos.ResponseResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Description :  查询所有频道
 * @Author :  Markburt
 * @CreateDate :  2020/3/8$ 下午 02:14$
 * @UpdateUser :  Markburt
 * @UpdateDate :  2020/3/8$ 下午 02:14$
 * @UpdateRemark :  Project Build
 * @Version :  1.0
 */

@RestController
@RequestMapping("/api/v1/channel")
public class AdChannelController implements AdChannelControllerApi {



    @Autowired
    private AdChannelService adChannelService;

    /***\
     * 查询所有频道
     * @return
     */
    @Override
    @RequestMapping("/channels")
    public ResponseResult selectAll() {
        return ResponseResult.okResult(adChannelService.selectAll()) ;
    }
}
